/*
 * application.h
 *
 *  Created on: 2009-1-6
 *      Author: fanliangliang
 */

#ifndef APPLICATION_H_
#define APPLICATION_H_

#include <stdint.h>

// forward declaration
class ConnectionListener;
class FileReceiver;
class FileSender;
class Uncompressor;

class Application {
public:
	Application();
	~Application();

	void start();
	void stop();

	int16_t status() const;

private:
	void startLog();
	void stopLog();
	void startWorkerThread();
	void stopWorkerThread();

private:
	ConnectionListener* listener_;
	FileReceiver* receiver_;
	FileSender* sender_;
	Uncompressor* uncompressor_;
	bool isRunning_;
};

#endif /* APPLICATION_H_ */
